<nz-card [nzBordered]="false" [nzTitle]="taskTitleTpl" [nzExtra]="taskExtraTpl" class="app-task-card">
  <ng-template #taskTitleTpl>
    <app-line-title title="待办信息"></app-line-title>
  </ng-template>
  <ng-template #taskExtraTpl>
    <button nz-button [nzSize]="'small'" nzType="primary" nzGhost (click)="toTaskList()">更多</button>
  </ng-template>

  <nz-alert nzType="warning" [nzMessage]="'您共有 '+taskObj.count+' 条待办信息未处理，请及时处理！'" nzShowIcon
    [hidden]="!(taskObj.tasks && taskObj.tasks.length)">
  </nz-alert>


  <nz-table nzTemplateMode class="app-task-table" [hidden]="!(taskObj.tasks && taskObj.tasks.length)">
    <tbody>
      <tr *ngFor="let task of taskObj.tasks;let i = index" (click)="toTaskInfo(task)">
        <td class="app-task-index">{{i+1}}</td>
        <td>
          <nz-tag [nzColor]="'blue'">{{task.createUser}}</nz-tag>
        </td>
        <td>{{task.title.length>35 ? (task.title | slice:0:35)+'...' : task.title }}</td>
        <td class="app-task-date">{{task.createDate}}</td>
      </tr>
    </tbody>
  </nz-table>

  <div class="app-task-empty-data" [hidden]="(taskObj.tasks && taskObj.tasks.length)">
    <app-custom-empty></app-custom-empty>
  </div>
</nz-card>